#-------------------------------------------------------------------------------
#!	@file Makefile
#!	@brief
#!		midi_in makefile
#!
#!	$Id: Makefile 277 2014-04-18 17:38:07Z ac.verbeck@gmail.com $
#-------------------------------------------------------------------------------
#-------------------------------------------------------------------------------
#	Copyright and Disclaimer Notice
#
#	Copyright (c) 2013 A.C. Verbeck
#
#	This file is part of midi_in
#
#	midi_in is free software: you can redistribute it and/or modify
#	it under the terms of the GNU General Public License as published by
#	the Free Software Foundation, either version 3 of the License, or
#	(at your option) any later version.
#
#	midi_in is distributed in the hope that it will be useful,
#	but WITHOUT ANY WARRANTY; without even the implied warranty of
#	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#	GNU General Public License for more details.
#
#	You should have received a copy of the GNU General Public License
#	along with midi_in.  If not, see <http://www.gnu.org/licenses/>.
#
#-------------------------------------------------------------------------------

#-------------------------------------------------------------------------------
#	Environment
#-------------------------------------------------------------------------------
BLD			= bldinfo
CFLAGS		= -Wall -Werror -ggdb -std=c99 -DBLD_DEBUG
LDLIBS		= -lpopt -lwinmm

#-------------------------------------------------------------------------------
#	Build environment
#-------------------------------------------------------------------------------
BLD_TARGET	= bi
BLD_VERSION	= 1.00


#-------------------------------------------------------------------------------
#	Targets
#-------------------------------------------------------------------------------
TARGET		= midi_in midi_ports

#-------------------------------------------------------------------------------
#	Rules
#-------------------------------------------------------------------------------
.PHONY:	all clean format

all:		$(TARGET)

clean:;		$(RM) *.o
			$(RM) *.bak
			$(RM) *.exe
			$(RM) *.c.orig
			$(RM) *.h.orig

format:;	astyle --style="k&r" --indent=tab --lineend=windows --recursive "*.c"

#-------------------------------------------------------------------------------
#	Dependencies
#-------------------------------------------------------------------------------
bldinfo:;	$(RM) bi.c bi.h

bi.c:;		$(BLD) --output=$(BLD_TARGET) --project=$(TARGET) --version=$(BLD_VERSION)		

midi_in:	midi_in.c bi.c p_mem.c debug.c cc_string.c mm_err.c

midi_ports:	midi_ports.c bi.c

#
#	End: Makefile
#
